package org.cash.cashrule;

import java.math.BigDecimal;

//打折
public class CashDiscount extends CashSuper {
    private Double discount;

    public CashDiscount(Double discount) {
        this.discount = discount;
    }

    @Override
    public BigDecimal acceptCash(BigDecimal money) {
        return money.multiply(new BigDecimal(this.discount.toString()));
    }
}
